In this How To we are going to build OpenSSL1.0.1e with our GCC 4.8.2 cross-compiler. Be sure to start this build in a new terminal/tab to avoid any pollution from previous builds. NOTE: This version of OpenSSL is affected by the Heartbleed Bug thus we will be using -DOPENSSL_NO_HEARTBEATS switch. Also, as recommended by OpenSSL we'll be building OpenSSL 1.0.1g.
Tar Balls
Here is a list of source packages that we'll need for the build. You can either download them now or wait 'til later in the How To.
openssl-1.0.1e.tar.gz
openssl-1.0.1e-fix_parallel_build-1.patch
openssl-1.0.1e-fix_pod_syntax-1.patch
openssl-1.0.1g.tar.gz
openssl-1.0.1g-fix_parallel_build-1.patch
openssl-1.0.1g-fix_pod_syntax-1.patch
Create a Workspace
I recommend creating a workspace under your /home/<your user>/ directory that is dedicated to this build. So let's fire up your terminal and run the following:
NOTE: Depending on whether you are using a cross-compiler built from my other wikis you might need to change INSTALLDIR to point to your cross-compiler.
cd into the final directory and output its contents:
$ cd ../
$ ls
You should have the following directories and file:
bin
certs
include
lib
man
misc
private
openssl.cnf
Make sure the binaries are for ARM:
$ cd bin/
$ file openssl
bash: ELF 32-bit LSB executable, ARM, version 1 (SYSV), dynamically linked (uses shared libs), for GNU/Linux 2.6.16, not stripped
If you see something similar to above you're good to go ;-)
Lastly, move the contents of these directories, or the directories themselves if they do not already exist, to your custom Linux file system or dev board. Read on to build OpenSSL 1.0.1g.
OpenSSL 1.0.1g
Create a Workspace
I recommend creating a workspace under your /home/<your user>/ directory that is dedicated to this build. In a new terminal:
NOTE: Depending on whether you are using a cross-compiler built from my other wikis you might need to change INSTALLDIR to point to your cross-compiler.
cd into the final directory and output its contents:
$ cd ../
$ ls
You should have the following directories and file:
bin
certs
include
lib
man
misc
private
openssl.cnf
Make sure the binaries are for ARM:
$ cd bin/
$ file openssl
bash: ELF 32-bit LSB executable, ARM, version 1 (SYSV), dynamically linked (uses shared libs), for GNU/Linux 2.6.16, not stripped
If you see something similar to above you're good to go ;-)
Lastly, move the contents of these directories, or the directories themselves if they do not already exist, to your custom Linux file system or dev board.
How To Build OpenSSL for ARM
Intro
In this How To we are going to build OpenSSL 1.0.1e with our GCC 4.8.2 cross-compiler. Be sure to start this build in a new terminal/tab to avoid any pollution from previous builds. NOTE: This version of OpenSSL is affected by the Heartbleed Bug thus we will be using -DOPENSSL_NO_HEARTBEATS switch. Also, as recommended by OpenSSL we'll be building OpenSSL 1.0.1g.
Tar Balls
Here is a list of source packages that we'll need for the build. You can either download them now or wait 'til later in the How To.
Create a Workspace
I recommend creating a workspace under your /home/<your user>/ directory that is dedicated to this build. So let's fire up your terminal and run the following:
Gather the Sources
Now that we have a workspace created and we are currently in the src directory we can begin bringing down the sources and extracting them.
openssl
Build Environment
To make things a little smoother let's setup some environment variables:
$ export INSTALLDIR=~/workbench/gcc-4.8.2/arm $ export PATH=$INSTALLDIR/bin:$PATH $ export TARGETMACH=arm-none-linux-gnueabi $ export BUILDMACH=i686-pc-linux-gnu $ export CROSS=arm-none-linux-gnueabi $ export CC=${CROSS}-gcc $ export LD=${CROSS}-ld $ export AS=${CROSS}-as $ export AR=${CROSS}-arNOTE: Depending on whether you are using a cross-compiler built from my other wikis you might need to change INSTALLDIR to point to your cross-compiler.Build OpenSSL
Output
cd into the final directory and output its contents:
You should have the following directories and file:
Make sure the binaries are for ARM:
If you see something similar to above you're good to go ;-)
Lastly, move the contents of these directories, or the directories themselves if they do not already exist, to your custom Linux file system or dev board. Read on to build OpenSSL 1.0.1g.
OpenSSL 1.0.1g
Create a Workspace
I recommend creating a workspace under your /home/<your user>/ directory that is dedicated to this build. In a new terminal:
Gather the Sources
Now that we have a workspace created and we are currently in the src directory we can begin bringing down the sources and extracting them.
openssl-1.0.1g
Build Environment
To make things a little smoother let's setup some environment variables:
$ export INSTALLDIR=~/workbench/gcc-4.8.2/arm $ export PATH=$INSTALLDIR/bin:$PATH $ export TARGETMACH=arm-none-linux-gnueabi $ export BUILDMACH=i686-pc-linux-gnu $ export CROSS=arm-none-linux-gnueabi $ export CC=${CROSS}-gcc $ export LD=${CROSS}-ld $ export AS=${CROSS}-as $ export AR=${CROSS}-arNOTE: Depending on whether you are using a cross-compiler built from my other wikis you might need to change INSTALLDIR to point to your cross-compiler.Build OpenSSL 1.0.1g
Output
cd into the final directory and output its contents:
You should have the following directories and file:
Make sure the binaries are for ARM:
If you see something similar to above you're good to go ;-)
Lastly, move the contents of these directories, or the directories themselves if they do not already exist, to your custom Linux file system or dev board.